<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
            table{
            border-collapse: collapse;
            width: 500px;
        }
        
        table tr td,
        table tr th {
            border: 1px solid rgb(27, 24, 24);
        }
        .icon img{
            width: 20px;
            height: 20px;
        }
        .icon{
            margin-left: 15px;
        }
    </style>
</head>

<body> 
    <div id="app" >
       <button :disabled=status >{{num}}</button>
       <button @click="change">点击</button>
    </div>
    <script src="./vue.js"></script>
    <script>
         var app = new Vue({
            el: "#app",
            data: {
                num :10,
                status:true
            },
            methods:{
             change(){
                console.log(11);
               var timer= setInterval(()=>{
                    this.num--
                    if (this.num==0) {
                        this.status=false
                        clearInterval(timer)
                    }
                },1000)
                
             }
             
                
            }
        })
    </script>
</body>

</html>